From 764e6d3cd8d28d702169048d8810528f4339162b Mon Sep 17 00:00:00 2001 From: oliskoli Date: Sat, 21 Apr 2007 16:40:40 +0000 Subject: [PATCH] bcr: Change handling of DESCRIPTION lines. Regenerate reference files. --- bcr.c | 5 ++++- reference/route/bcr-sample2.bcr | 18 +++++++++--------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/bcr.c b/bcr.c index 4d0ad1318..c9eaf340e 100644 --- a/bcr.c +++ b/bcr.c @@ -431,7 +431,10 @@ bcr_route_header(const route_head *route) if (s2 == NULL) s2 = xstrdup(""); else s2 = csv_stringclean(s2, ",\t\r\n"); - xasprintf(&sout, "%s,%s,,0", s1, s2); + if (*s2) + xasprintf(&sout, "%s,%s,@,0", s1, s2); + else + xasprintf(&sout, "%s,%s,@,0", s1, s1); bcr_write_line(fout, "STATION", &i, sout); xfree(s1); diff --git a/reference/route/bcr-sample2.bcr b/reference/route/bcr-sample2.bcr index a630c3916..88f13cba2 100644 --- a/reference/route/bcr-sample2.bcr +++ b/reference/route/bcr-sample2.bcr @@ -22,14 +22,14 @@ STATION7=1389101,6644184 STATION8=1377578,6656081 STATION9=1379831,6669676 [DESCRIPTION] -STATION1=bei D 08527,Neundorf,,0 -STATION2=bei D 08523,Plauen/Possig,,0 -STATION3=bei D 08523,Plauen/Westend,,0 -STATION4=bei D 08427,Fraureuth/Beiersdorf,,0 -STATION5=bei D 04639,Ponitz/Merlach,,0 -STATION6=bei D 04600,Altenburg/Paditz,,0 -STATION7=bei D 04552,Borna/Gestewitz,,0 -STATION8=bei D 04564,Boehlen/Grossdeuben,,0 -STATION9=bei D 04317,Leipzig/Thonberg,,0 +STATION1=bei D 08527,Neundorf,@,0 +STATION2=bei D 08523,Plauen/Possig,@,0 +STATION3=bei D 08523,Plauen/Westend,@,0 +STATION4=bei D 08427,Fraureuth/Beiersdorf,@,0 +STATION5=bei D 04639,Ponitz/Merlach,@,0 +STATION6=bei D 04600,Altenburg/Paditz,@,0 +STATION7=bei D 04552,Borna/Gestewitz,@,0 +STATION8=bei D 04564,Boehlen/Grossdeuben,@,0 +STATION9=bei D 04317,Leipzig/Thonberg,@,0 [ROUTE] ROUTERECT=1346067,6669676,1389101,6524736 -- 2.30.2